export default {
	state: {
		token: false,
		status: false,
		userInfo: uni.getStorageSync('userinfo') || []
	},
	mutations: {
		getUserInfo(state, payload) {
			state.token = payload.token
			state.status = payload.status
			state.userInfo = payload
			uni.setStorageSync('userinfo', payload)
			uni.setStorageSync('token', payload.token)
		},
		//退出登录时移除所有信息S
		removeUserInfo(state) {
			uni.removeStorageSync('userinfo')
			state.token = false
			state.status = false
			state.userInfo = []
		}
	},
	getters: {

	},
	actions: {

	}
}